package evol

class OsnovniController {

    def index() {
		
		 }
	 def beforeInterceptor = [action:this.&auth]
	 
	 def auth() {
		 if(!(session?.user?.role=="admin")) {
			 flash.message="Morate biti administrator da bi ste pristupili toj stranici"
			 
		   redirect(controller:"korisnik", action:"login")
		   return false
		 }
	   }
	
}
